package com.java9s.goldchit.utils;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;

public class GoldChitUtils {

	public static Date converStringToUtilDate(String date)
			throws ParseException {
		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
		Date utilDate = (Date) formatter.parse(date);
		return utilDate;
	}

	public static String converDateToString(Date date) throws ParseException {
		SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
		String stringDate = formatter.format(date);
		return stringDate;
	}
}
